
/*
 * @copyright
 *   © 2016-2017 Jarosław Foksa
 * @info
 *   Theme based on Material Design guidelines.
 */

body {
  width: 100%;
  height: 100%;
  margin: 0;
  background: #eeeeee;
  color: var(--text-color);
  font-family: "Roboto", "Noto Sans", sans-serif;
  font-size: 15px;
  line-height: 1.6;
  overflow-y: overlay;
  --primary-color: #009788;
  --secondary-color:  #2196f3;
  --accent-color: #ecec26;
  --link-color: #009788;
  --text-color: rgba(0, 0, 0, 0.8);
  --transition-fn1: cubic-bezier(0.4, 0, 0.2, 1);
  --elevation-1:  0px  2px  1px -1px rgba(0,0,0,0.2), 0px  1px  1px 0px rgba(0,0,0,0.14), 0px 1px  3px 0px rgba(0,0,0,0.12);
  --elevation-1a: 0px  2px  1px -1px rgba(0,0,0,0.1), 0px  1px  1px 0px rgba(0,0,0,0.05), 0px 1px  3px 0px rgba(0,0,0,0.12);
  --elevation-2:  0px  3px  1px -2px rgba(0,0,0,0.2), 0px  2px  2px 0px rgba(0,0,0,0.14), 0px 1px  5px 0px rgba(0,0,0,0.12);
  --elevation-5:  0px  3px  5px -1px rgba(0,0,0,0.2), 0px  5px  8px 0px rgba(0,0,0,0.14), 0px 1px 14px 0px rgba(0,0,0,0.12);
  --elevation-16: 0px  8px 10px -5px rgba(0,0,0,0.2), 0px 16px 24px 2px rgba(0,0,0,0.14), 0px 6px 30px 5px rgba(0,0,0,0.12);
  --elevation-24: 0px 11px 15px -7px rgba(0,0,0,0.2), 0px 24px 38px 3px rgba(0,0,0,0.14), 0px 9px 46px 8px rgba(0,0,0,0.12);
}

h2 {
  box-sizing: border-box;
  margin: 36px 0 20px 0;
  font-size: 44px;
  font-weight: 700;
  line-height: 1.1;
  color: rgb(0, 151, 136);
}

h3 {
  box-sizing: border-box;
  font-size: 26px;
  font-weight: 500;
  line-height: 32px;
  color: rgba(0, 0, 0, 0.85);
  margin-bottom: 30px;
}

h4 {
  box-sizing: border-box;
  font-size: 20px;
  font-weight: 500;
  color: rgba(0, 0, 0, 0.85);
  margin-bottom: 15px;
}

h5 {
  box-sizing: border-box;
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  color: rgba(0, 0, 0, 0.85);
  margin-bottom: 8px;
}

p:last-child {
  margin-bottom: 0;
}

em {
  font-weight: 500;
}

pre,
code,
var {
  font-family: "Roboto Mono", monospace;
  font-style: normal;
  background: #F8F8FF;
  outline: rgba(0, 0, 0, 0.3) dashed 1px;
}

hr {
  background: rgba(0, 0, 0, 0.12);
  border: none;
  width: 100%;
  height: 1px;
  min-height: 1px;
  margin: 2px 0px 2px 0;
  box-sizing: border-box;
}

a {
  text-decoration: none;
}
p a,
li a,
dl a,
h2 a,
h3 a,
h4 a,
h5 a,
h6 a,
x-label a {
  color: var(--link-color);
  text-decoration: underline;
}
p a:hover,
li a:hover
dl a:hover,
h2 a:hover,
h3 a:hover,
h4 a:hover,
h5 a:hover,
h6 a:hover,
x-label a:hover {
  text-decoration: none;
}

input[type="text"] {
  cursor: default;
}
input[type="text"]:hover {
  cursor: text;
}

sidebar {
  background: white;
}

/**
 * Navigation
 */

nav {
  box-sizing: border-box;
  padding: 0 30px;
}

nav section {
  margin: 10px 0;
}

nav h3 {
  color: rgba(0, 0, 0, 0.45);
  margin: 0;
  padding: 0;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  user-select: none;
  cursor: default;
}

nav hr {
  margin: 0 0 0 -30px;
  width: calc(100% + 60px);
}

/**
 * Selection
 */

::selection {
  background: var(--primary-color);
  color: white;
}
:host([error]) ::selection {
  background: #d50000;
}

/**
 * Scrollbar
 */

::-webkit-scrollbar {
  max-width: 6px;
  max-height: 6px;
  background: none;
}

::-webkit-scrollbar-thumb {
  background-color: rgba(0, 0, 0, 0.2);
}

::-webkit-scrollbar-corner {
  display: none
}

/**
 * Dialog (https://material.google.com/components/dialogs.html)
 */

dialog {
  position: fixed;
  width: 70%;
  height: auto;
  min-height: 100px;
  padding: 0;
  box-sizing: border-box;
  transition: transform 300ms cubic-bezier(0.0, 0.0, 0.2, 1);
  border: 1px solid #a9a9a9;
  color: inherit;
  background: white;
  box-shadow: var(--elevation-24);
  text-transform: none;
}
dialog::backdrop {
  background: rgba(0, 0, 0, 0.5);
}

dialog h3 {
  font-size: 25px;
  color: rgba(0, 0, 0, 0.95);
  margin-top: 0;
  margin-bottom: 10px;
}

dialog > main {
  padding: 20px 35px 0px;
  font-size: 15px;
  line-height: 1.6;
  color: rgba(0, 0, 0, 0.6);
}

dialog > footer {
  padding: 12px;
  display: flex;
  flex-flow: row;
  justify-content: flex-end;
  margin-top: auto;
}

dialog > footer x-button:last-child {
  margin-left: 15px;
  margin-right: 5px;
}

/*****************************************************************************************************************/

/**
 * Card (https://material.google.com/components/cards.html)
 */

x-card {
  background: white;
  box-shadow: var(--elevation-1);
  border-radius: 2px;
}

x-card > header {
  padding: 15px 30px;
  display: flex;
  align-items: center;
  background: #f9f9f9;
  border-top: 1px solid #e6e6e6;
  border-bottom: 1px solid #e0e0e0;
}

x-card > header h3 {
  margin: 0;
  flex: 1;
  line-height: 1;
}

x-card > header x-switch {
  margin: 0;
}

x-card > main {
  padding: 30px;
}

x-card > main h3:first-child {
  margin-top: 0;
}

x-card main > p {
  line-height: 18px;
  margin: 10px 0;
}
x-card main > p:first-child {
  margin-top: 0;
}

/*****************************************************************************************************************/

/**
 * Accordion (https://material.io/guidelines/components/expansion-panels.html#expansion-panels-behavior)
 */

x-accordion {
  --arrow-color: rgba(0, 0, 0, 0.38);
  --focused-arrow-background: rgba(0, 0, 0, 0.08);
  --trigger-effect: ripple;
}

x-accordion > header {
  display: flex;
  align-items: center;
  box-sizing: border-box;
  width: 100%;
  min-height: 48px;
  padding: 10px 50px 10px 24px;
}

x-accordion > header > x-label {
  color: rgba(0, 0, 0, 0.54);
}
x-accordion > header > x-label strong {
  font-weight: 500;
  color: rgba(0, 0, 0, 0.87);
}

x-accordion > main {
  padding: 10px 24px 24px 24px;
}
x-accordion:not([expanded]):not([animating]) > main {
  display: none;
}

x-accordion + hr {
  margin: 0;
}

/*****************************************************************************************************************/

/**
 * Icon (https://material.google.com/style/icons.html#icons-system-icons)
 */

x-icon {
  width: 24px;
  height: 24px;
}

/* @skin "primary" */

x-icon[skin="primary"] {
  width: 32px;
  height: 32px;
  color: rgba(0, 0, 0, 0.5);
}

/*****************************************************************************************************************/

/**
 * Stepper
 */

x-stepper {
  flex-flow: column-reverse;
  overflow: hidden;
  box-sizing: border-box;
  width: 27px;
  height: 100%;
  background: white;
  color: rgba(0, 0, 0, 0.8);
  --button-border-left: 1px solid rgba(0, 0, 0, 0.1);
  --pressed-button-background: rgba(0, 0, 0, 0.4);
  --increment-arrow-width: 15px;
  --increment-arrow-height: 15px;
  --decrement-arrow-width: 15px;
  --decrement-arrow-height: 15px;
}

/*****************************************************************************************************************/

/**
 * Swatch
 */

x-swatch {
  border-radius: 2px;
}

/*****************************************************************************************************************/

/**
 * Buttons (https://material.google.com/components/buttons.html)
 */

x-button {
  min-height: 34px;
  padding: 5px 14px;
  color: var(--secondary-color);
  background: white;
  border-radius: 2px;
  box-shadow: var(--elevation-2);
  font-size: 13px;
  text-transform: uppercase;
  font-weight: 500;
  --trigger-effect: ripple;
  --arrow-width: 11px;
  --arrow-height: 11px;
  --arrow-d: path("M 0.736 20.365 L 49.999 87.922 L 99.264 20.365 Z");
}
x-button:focus::before {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: block;
  background: currentColor;
  opacity: 0.1;
  content: "";
}
x-button[toggled] {
  color: white;
  background: var(--secondary-color);
  box-shadow: var(--elevation-1a);
}

x-button > x-label,
x-button > x-box > x-label {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

x-button > x-box {
  overflow: hidden;
  align-items: center;
}

x-button > x-box > * {
  margin: 0 6px 0 0;
}
x-button > x-box > *:last-child {
  margin: 0;
}

x-button > x-box[vertical] > * {
  margin: 0 0 4px 0;
}
x-button > x-box[vertical] > *:last-child {
  margin: 0;
}

x-buttons[hasboxshadow] {
  box-shadow: var(--elevation-2);
}

x-buttons[hasboxshadow] > x-button,
x-buttons[hasboxshadow] > x-button[toggled] {
  box-shadow: none;
}
x-buttons > x-button:not(:first-child) {
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}
x-buttons > x-button:not(:last-child) {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

/* @skin "textured" */

x-button[skin="textured"] {
  color: rgba(0, 0, 0, 0.5);
  background-image: linear-gradient(to bottom, #FCFCFC, #F1F1F1);
}
x-button[skin="textured"][toggled] {
  color: rgba(0, 0, 0, 0.7);
  background: rgba(0, 0, 0, 0.08);
}

/* @skin "flat" */

x-button[skin="flat"] {
  color: var(--primary-color);
  background: none;
  box-shadow: none;
}
x-button[skin="flat"][toggled]::after {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: block;
  background: currentColor;
  opacity: 0.15;
  content: "";
}

/* @skin "iconic" */

x-button[skin="iconic"] {
  background: none;
  box-shadow: none;
  padding: 6px;
  color: rgba(0, 0, 0, 0.55);
  border-radius: 2px;
  --trigger-effect: unbounded-ripple;
  --ripple-opacity: 0.1;
  --arrow-margin: 0 0 0 2px;
}
x-button[skin="iconic"][expanded],
x-button[skin="iconic"][toggled] {
  color: var(--secondary-color);
}
x-button[skin="iconic"]:focus::before {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: block;
  background: currentColor;
  border-radius: 999px;
  opacity: 0.1;
  transform: scale(1.3);
  content: "";
}

x-button[skin="iconic"] > x-icon {
  width: 30px;
  height: 30px;
  color: inherit;
}

/* @skin "nav" */

x-button[skin="nav"] {
  padding: 8px 15px;
  font-size: 15px;
  cursor: default;
  color: #4a4a4a;
  box-shadow: none;
  text-transform: none;
  border-radius: 0;
  overflow: hidden;
}

x-button[skin="nav"][toggled] {
  color: white;
  background: var(--primary-color);
}

x-button[skin="nav"] x-icon {
  width: 24px;
  height: 24px;
  opacity: 0.9;
  margin-right: 12px;
}

x-button[skin="nav"] x-label {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-weight: 500;
}

/*****************************************************************************************************************/

/**
 * Tabs (https://material.google.com/components/tabs.html)
 */

x-tabs {
  background: var(--primary-color);
  padding: 0 15px;
}

x-tab {
  padding: 8px 24px;
  max-width: 264px;
  min-height: 52px;
  color: rgba(255, 255, 255, 0.7);
  --trigger-effect: ripple;
  --menu-position: over;
  --arrow-width: 11px;
  --arrow-height: 9px;
  --arrow-margin: 0 0 1px 5px;
  --arrow-d: path("M 0.736 20.365 L 49.999 87.922 L 99.264 20.365 Z");
}
x-tab[selected],
x-tab:focus {
  color: white;
}

x-tab > x-icon,
x-tab > x-box > x-icon {
  color: inherit;
  width: 24px;
  min-width: 24px;
  height: 24px;
}

x-tab > x-label,
x-tab > x-box > x-label {
  color: inherit;
  box-sizing: border-box;
  overflow: hidden;
  white-space: nowrap;
  cursor: inherit;
  font-size: 14px;
  font-weight: 500;
  text-transform: uppercase;
  line-height: 1;
}

x-tab > x-box[vertical] {
  align-items: center;
}

x-tab > x-box > * {
  margin: 0 8px 0 0;
}
x-tab > x-box > *:last-child {
  margin: 0 0 0 0;
}

x-tab > x-box[vertical] > * {
  margin: 0 0 6px 0;
}
x-tab > x-box[vertical] > *:last-child {
  margin: 0 0 3px 0;
}

/* Bright skin */

x-tabs[skin="flat"] {
  padding: 0;
  background: none;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

x-tabs[skin="flat"] x-tab {
  color: rgba(0, 0, 0, 0.6);
}
x-tabs[skin="flat"] x-tab[selected] {
  color: var(--primary-color);
  --selection-indicator-background: var(--primary-color);
}

/* Compact skin */

x-tabs[skin="compact"] {
  box-shadow: var(--elevation-5);
}

x-tabs[skin="compact"] x-tab {
  padding: 2px 12px;
  width: fit-content;
  flex: 0;
  flex-flow: column;
  color: rgba(255, 255, 255, 0.75);
  --ripple-type: bounded;
  --selection-indicator-height: 0;
}

x-tabs[skin="compact"] x-tab:focus,
x-tabs[skin="compact"] x-tab[selected] {
  color: white;
}

x-tabs[skin="compact"] x-label {
  position: relative;
  margin-top: 3px;
  font-size: 14px;
  transition: transform 0.2s var(--transition-fn1);
  transform: scale(0.85, 0.85);
  transform-origin: center center;
  text-transform: none;
}
x-tabs[skin="compact"] x-tab[selected] x-label {
  color: white;
  transform: scale(1, 1);
}

/*****************************************************************************************************************/

/**
 * Document tabs
 */

x-doctabs {
  background: var(--primary-color);
  color: white;
  height: 46px;
  --open-button-path-d: path("M 80 11 L 20 12 C 15 12 12 15 12 20 L 12 80 C 12 85 15 88 20 88 L 80 88 C 85 88 88 85 88 80 L 88 20 C 88 15 85 12 80 12 Z M 71 54 L 54 54 L 54 71 L 46 71 L 46 54 L 29 54 L 29 46 L 46 46 L 46 29 L 54 29 L 54 46 L 71 46 L 71 54 Z");
}

x-doctab {
  font-size: 14px;
  font-weight: 500;
  --ripple-type: bounded;
}

x-doctab img {
  margin-right: 8px;
  width: 20px;
  height: 20px;
}

x-doctab x-icon {
  margin-right: 8px;
}

x-doctab x-label {
  flex: 1;
  width: 0; /* https://lists.w3.org/Archives/Public/www-style/2011Jan/0201.html */
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

x-doctab > * {
  opacity: 0.75;
}
x-doctab[selected] > *,
x-doctab:focus > * {
  opacity: 1;
}
x-doctab[disabled] > * {
  opacity: 0.5;
}

/*****************************************************************************************************************/

/**
 * Menu (https://material.google.com/components/menus.html)
 */

x-menu {
  padding: 8px 0;
  color: var(--text-color);
  border-radius: 2px;
  box-shadow: var(--elevation-5);
  font-size: 15px;
  text-transform: none;
  font-weight: 400;
  --open-transition: 100 transform var(--transition-fn1);
}

x-menu > hr {
  width: 100%;
  height: 1px;
  margin: 2px 0px 2px 0;
  box-sizing: border-box;
  border-color: rgba(0, 0, 0, 0.12);
}
x-menu > hr + hr,
x-menu > hr:last-child {
  display: none;
}

/*****************************************************************************************************************/

/**
 * Menu item (https://material.google.com/components/menus.html#menus-menu-items)
 */

x-menuitem {
  padding: 0 20px;
  min-height: 38px;
  --trigger-effect: ripple;
}
x-menuitem:focus,
x-menuitem[expanded] {
  background: rgba(0, 0, 0, 0.07);
}

x-menuitem img {
  width: 24px;
  height: 24px;
}

x-menuitem x-icon {
  opacity: 0.7;
}

x-menuitem x-label {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

x-menuitem x-shortcut {
  margin-left: auto;
  color: #212121;
  opacity: 0.75;
}

x-menuitem img + x-label,
x-menuitem x-swatch + x-label,
x-menuitem x-icon + x-label,
x-menuitem x-label + x-shortcut {
  margin-left: 12px;
}

/*****************************************************************************************************************/

/**
 * Menubar (https://material.google.com/components/menus.html)
 */

x-menubar {
  height: 38px;
  background: white;
  box-shadow: var(--elevation-1);
}

x-menubar > x-menuitem {
  padding: 0 20px;
  height: 100%;
}

/*****************************************************************************************************************/

/**
 * Popover
 */

x-popover {
  color: var(--text-color);
  border: 1px solid rgba(0, 0, 0, 0.15);
  border-radius: 2px;
  box-shadow: var(--elevation-5);
  font-size: 15px;
  font-weight: 400;
  text-transform: none;
  --open-transition: 100 transform var(--transition-fn1);
}

x-popover > main {
  width: 100%;
  padding: 20px;
  overflow: auto;
}

/*****************************************************************************************************************/

/**
 * Notification
 */

x-notification {
  bottom: 0;
  padding: 14px 24px;
  text-transform: none;
  font-size: 14px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.85);
  background: #323232;
  min-width: 288px;
  max-width: 568px;
  border-top-left-radius: 2px;
  border-top-right-radius: 2px;
}

x-notification strong {
  color: white;
}

/*****************************************************************************************************************/

/**
 * Checkbox (https://material.google.com/components/selection-controls.html#selection-controls-checkbox)
 */

x-checkbox {
  color: #6d6d6d;
  border: 3px solid currentColor;
  border-radius: 3px;
  transition: color 0.2s var(--transition-fn1);
  --ripple-type: none;
}
x-checkbox[toggled] {
  color: var(--primary-color);
}
@media (pointer:coarse) {
  x-checkbox {
    --ripple-type: unbounded;
  }
}

x-checkbox::before {
  position: absolute;
  width: 100%;
  height: 100%;
  display: block;
  content: "";
  background: currentColor;
  border-radius: 999px;
  opacity: 0.15;
  top: 0;
  left: 0;
  will-change: transform;
  transition: transform 0.15s var(--transition-fn1);
  transform: scale(0);
}
x-checkbox:focus::before {
  transform: scale(2.6);
}

/*****************************************************************************************************************/

/**
 * Radio (https://material.google.com/components/selection-controls.html#selection-controls-radio-button)
 */

x-radio {
  width: 18px;
  height: 18px;
  color: var(--primary-color);
  border: 3px solid currentColor;
  --dot-color: currentColor;
}
x-radio[disabled] {
  color: #525252;
}

x-radio::before {
  position: absolute;
  width: 100%;
  height: 100%;
  display: block;
  content: "";
  background: currentColor;
  border-radius: 999px;
  opacity: 0.15;
  top: 0;
  left: 0;
  will-change: transform;
  transition: transform 0.15s var(--transition-fn1);
  transform: scale(0);
}
x-radio:focus::before {
  transform: scale(2.6);
}

x-radio + x-label {
  margin-left: 7px;
  padding: 8px 0;
}

/*****************************************************************************************************************/

/**
 * Switch (https://material.google.com/components/selection-controls.html#selection-controls-switch)
 */

x-switch {
  color: var(--primary-color);
  transition: filter 0.2s var(--transition-fn1);
  filter: saturate(0%);
  --ripple-type: none;
}
x-switch[toggled] {
  filter: none;
}
@media (pointer:coarse) {
  x-switch {
    --ripple-type: unbounded;
  }
}

/* Big skin */

x-switch[skin="big"] {
  width: 40px;
  --thumb-size: 22px;
  --track-height: 80%;
}

/*****************************************************************************************************************/

/**
 * Select (https://material.io/guidelines/components/buttons.html#buttons-dropdown-buttons)
 */

x-select {
  background: white;
  color: #646464;
  border: 1px solid rgba(0, 0, 0, 0.2);
  border-radius: 2px;
  height: 36px;
  padding: 0 4px 0 10px;
  --arrow-width: 15px;
  --arrow-min-width: 15px;
  --arrow-height: 15px;
  --arrow-margin: 0 3px 0 15px;
  --arrow-d: path("M 24.85 63.241 L 51.609 98.098 L 78.367 63.241 Z M 78.367 35.581 L 51.609 0.724 L 24.85 35.581 Z");
}
x-select:focus {
  border-bottom-color: var(--primary-color);
  box-shadow: 0px 1px 0px var(--primary-color);
}

/* Flat skin */

x-select[skin="flat"] {
  background: none;
  border: none;
  border-bottom: 2px solid #b3b3b3;
  padding: 0;
}

/*****************************************************************************************************************/

/**
 * Input
 */

x-input {
  height: 34px;
  max-width: 160px;
  color: var(--text-color);
  border: 1px solid #c1c1c1;
  outline: none;
  font-size: 13px;
  --selection-color: white;
  --selection-background: var(--primary-color);
  --inner-padding: 0px 7px;
}
x-input[readonly] {
  color: rgba(0, 0, 0, 0.75);
}
x-input[error] {
  --selection-background: #d50000;
}

/* Error text */
x-input[error]::before {
  top: 37px;
}

/* Focus indicator line */
x-input::after {
  content: "";
  display: block;
  position: absolute;
  width: 0%;
  height: 3px;
  bottom: -1px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary-color);
  transition: width 0.2s var(--transition-fn1);
}
x-input:focus::after {
  width: 100%;
}
x-input[error]::after {
  width: 100%;
  background: #d50000;
}

/* Icon */
x-input > x-icon {
  width: 32px;
  height: 32px;
  min-width: 32px;
  padding: 7px;
  box-sizing: border-box;
  color: #565656;
  background: rgba(0, 0, 0, 0.08);
  border-right: 1px solid #c1c1c1;
}
x-input > x-icon:hover {
  cursor: default;
}

/* Placeholder */
x-input > x-label {
  display: none;
  position: absolute;
  top: 50%;
  max-width: 100%;
  padding: 0 7px 0 7px;
  transform: translateY(-50%);
  color: rgba(0, 0, 0, 0.4);
  font-family: inherit;
  font-size: inherit;
  line-height: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  pointer-events: none;
}
x-input[empty] > x-label {
  display: block;
}
x-input > x-icon + x-label {
  padding: 0 7px 0 39px;
}
x-input[required] > x-label::after {
  content: "*";
}

/* @skin "flat" */

x-input[skin="flat"] {
  height: 28px;
  background: none;
  border-left: none;
  border-right: none;
  border-top: none;
  --inner-padding: 0;
}
x-input[skin="flat"] + x-input[skin="flat"] {
  margin-top: 28px;
}

/* Icon */
x-input[skin="flat"] > x-icon {
  width: 34px;
  height: 34px;
  min-width: 34px;
  margin: 0 0 0 -34px;
  background: none;
  border: none;
  cursor: default;
  transition: color 0.2s var(--transition-fn1);
}
x-input[skin="flat"]:focus > x-icon {
  color: var(--primary-color);
}
x-input[skin="flat"][error] > x-icon {
  color: #d50000;
}

/* Placehodler */
x-input[skin="flat"] > x-label {
  display: block;
  padding: 0;
  transition-property: top, color, font-size;
  transition-duration: 0.2s;
  transition-timing-function: var(--transition-fn1);
}
x-input[skin="flat"]:not([empty]) > x-label,
x-input[skin="flat"]:focus > x-label {
  top: calc(50% - 18px);
  color: var(--primary-color);
  font-size: 12px;
  pointer-events: all;
}
x-input[skin="flat"][error]:not([empty]) > x-label,
x-input[skin="flat"][error] > x-label {
  color: #d50000;
}
x-input[skin="flat"]:focus > x-label::after {
  color: #d50000;
}
x-input[skin="flat"] > x-icon + x-label {
  left: 0px;
}

/*****************************************************************************************************************/

/**
 * Date select
 */

x-dateselect {
  height: 34px;
  max-width: 160px;
  color: var(--text-color);
  border: 1px solid #c1c1c1;
  outline: none;
  font-size: 13px;
  --inner-padding: 0px 7px;
}

/* Error text */
x-dateselect[error]::before {
  top: 37px;
}

/* Focus indicator line */
x-dateselect::after {
  content: "";
  display: block;
  position: absolute;
  width: 0%;
  height: 3px;
  bottom: -1px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary-color);
  transition: width 0.2s var(--transition-fn1);
}
x-dateselect:focus::after {
  width: 100%;
}
x-dateselect[error]::after {
  width: 100%;
  background: #d50000;
}

/* Placeholder */
x-dateselect > x-label {
  display: none;
  position: absolute;
  top: 50%;
  max-width: 100%;
  padding: 0 7px 0 7px;
  transform: translateY(-50%);
  color: rgba(0, 0, 0, 0.4);
  font-family: inherit;
  font-size: inherit;
  line-height: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  pointer-events: none;
}
x-dateselect[empty] > x-label {
  display: block;
}
x-dateselect[required] > x-label::after {
  content: "*";
}

x-dateselect:active > x-label,
x-dateselect:focus > x-label {
  display: none;
}

/* @skin "flat" */

x-dateselect[skin="flat"] {
  height: 28px;
  background: none;
  border-left: none;
  border-right: none;
  border-top: none;
  --inner-padding: 0;
}
x-dateselect[skin="flat"] + x-dateselect[skin="flat"] {
  margin-top: 28px;
}

/* Placehodler */
x-dateselect[skin="flat"] > x-label {
  display: block;
  padding: 0;
  transition-property: top, color, font-size;
  transition-duration: 0.2s;
  transition-timing-function: var(--transition-fn1);
}
x-dateselect[skin="flat"]:not([empty]) > x-label,
x-dateselect[skin="flat"]:focus > x-label {
  display: block;
  top: calc(50% - 18px);
  color: var(--primary-color);
  font-size: 12px;
  pointer-events: all;
}
x-dateselect:active > x-label {
  display: block;
}
x-dateselect[skin="flat"][error]:not([empty]) > x-label,
x-dateselect[skin="flat"][error] > x-label {
  color: #d50000;
}
x-dateselect[skin="flat"]:focus > x-label::after {
  color: #d50000;
}

/*****************************************************************************************************************/

/**
 * Number input
 */

x-numberinput {
  background: white;
  color: var(--text-color);
  font-size: 13px;
  border: 1px solid #c1c1c1;
  height: 34px;
  max-width: 160px;
  outline: none;
  --inner-padding: 0px 7px;
  --selection-color: white;
  --selection-background: var(--primary-color);
}
x-numberinput[error] {
  --selection-background: #d50000;
}

/* Focus indicator line */
x-numberinput::after {
  content: "";
  display: block;
  width: 0%;
  height: 3px;
  bottom: -1px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary-color);
  position: absolute;
  transition: width 0.2s var(--transition-fn1);
}
x-numberinput:focus::after {
  width: 100%;
}
x-numberinput[error]::after {
  width: 100%;
  background: #d50000;
}

/* Placeholder */
x-numberinput > x-label {
  display: none;
  position: absolute;
  width: 100%;
  height: 22px;
  bottom: 6px;
  top: 50%;
  left: 0;
  padding: 0 7px;
  transform: translateY(-50%);
  line-height: 1.8;
  color: rgba(0, 0, 0, 0.4);
  font-family: inherit;
  pointer-events: none;
}
x-numberinput[empty] > x-label {
  display: block;
  cursor: text;
}
x-numberinput[required] > x-label::after {
  content: "*";
}
x-numberinput > x-icon + x-label {
  left: 32px;
}

/*****************************************************************************************************************/

/**
 * Tag input
 */

x-taginput {
  background: white;
  color: var(--text-color);
  font-size: 13px;
  border: 1px solid #c1c1c1;
  outline: none;
  --selection-color: white;
  --selection-background: var(--primary-color);
}
x-taginput[error] {
  --selection-background: #d50000;
}

x-taginput > x-label {
  align-self: center;
  margin-left: -8px;
  color: rgba(0, 0, 0, 0.4);
}

/* Focus indicator line */
x-taginput::after {
  content: "";
  display: block;
  width: 0%;
  height: 3px;
  bottom: -1px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary-color);
  position: absolute;
  transition: width 0.2s var(--transition-fn1);
}
x-taginput:focus::after {
  width: 100%;
}
x-taginput[error]::after {
  width: 100%;
  background: #d50000;
}

/*****************************************************************************************************************/

/**
 * Textarea
 */

x-textarea {
  min-height: 120px;
  color: var(--text-color);
  font-size: 13px;
  border: 1px solid #c1c1c1;
  outline: none;
  --selection-color: white;
  --selection-background: var(--primary-color);
  --inner-padding: 3px 6px;
}

/* Focus indicator line */
x-textarea::after {
  content: "";
  display: block;
  width: 0%;
  height: 3px;
  bottom: -1px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary-color);
  position: absolute;
  transition: width 0.2s var(--transition-fn1);
}
x-textarea:focus::after {
  width: 100%;
}
x-textarea[error]::after {
  width: 100%;
  background: #d50000;
}

/* Placeholder */
x-textarea > x-label {
  display: none;
  position: absolute;
  width: 100%;
  top: 0;
  left: 0;
  padding: var(--inner-padding);
  color: rgba(0, 0, 0, 0.4);
  font-family: inherit;
  line-height: inherit;
  pointer-events: none;
}
x-textarea[empty] > x-label {
  display: block;
  cursor: text;
}
x-textarea[required] > x-label::after {
  content: "*";
}

/* @skin "flat" */

x-textarea[skin="flat"] {
  background: none;
  border-left: none;
  border-right: none;
  border-top: none;
  min-height: 0;
  max-height: none;
  padding: 0;
  --inner-padding: 9px 0px 5px;
}

x-textarea[skin="flat"] > x-label {
  display: block;
  top: 6px;
  padding: 0;
  transform: none;
  transition-property: top, color, font-size;
  transition-duration: 0.2s;
  transition-timing-function: var(--transition-fn1);
}
x-textarea[skin="flat"]:not([empty]) > x-label,
x-textarea[skin="flat"]:focus > x-label {
  top: -12px;
  font-size: 12px;
  color: var(--primary-color);
  pointer-events: all;
}
x-textarea[skin="flat"][error]:not([empty]) > x-label,
x-textarea[skin="flat"][error] > x-label {
  color: #d50000;
}
x-textarea[skin="flat"]:focus > x-label::after {
  color: #d50000;
}

/*****************************************************************************************************************/

/**
 * Slider
 */

x-slider {
  --thumb-width: 16px;
  --thumb-height: 16px;
  --thumb-color: var(--primary-color);
  --thumb-border-width: 0px;
  --track-height: 3px;
  --track-color: #B9B9B9;
  --track-tint-color: var(--primary-color);
  --focus-ring-color: var(--primary-color);
  --focus-ring-opacity: 0.2;
  --focus-ring-width: 20px;
}
x-slider[value="0"] {
  --thumb-color: #B9B9B9;
  --focus-ring-color: #B9B9B9;
  --focus-ring-opacity: 0.3;
}
x-slider:active {
  --thumb-transform: scale(1.4);
}

x-box x-icon + x-slider,
x-box x-slider + x-icon {
  margin-left: 10px;
}
x-box[vertical] x-icon + x-slider,
x-box[vertical] x-slider + x-icon {
  margin-left: 0;
}

/*****************************************************************************************************************/

/**
 * Progressbar
 */

x-progressbar {
  background: rgba(59, 153, 251, 0.27);
  height: 5px;
  --bar-background: #3B99FB;
  --bar-box-shadow: 0px 0px 0px 1px #4392F9;
}

/*****************************************************************************************************************/

/**
 * Demo site
 */

xel-codeview {
  box-shadow: var(--elevation-1);
}
x-card xel-codeview {
  background: #fbfbfb;
}

:host(xel-app) #sidebar h1 {
  color: #009788;
}

:host(xel-app) #sidebar #nav .external-link-icon {
  color: var(--primary-color);
}

:host(xel-app) #about-view {
  background: #009788;
}

:host(xel-app) #setup-view h3 x-icon {
  color: #009788;
}

:host(xel-app) #faq-view h4 {
  color: #009788;
}
